home *** CD-ROM | disk | FTP | other *** search
/ Apple WWDC 1996 / WWDC96_1996 (CD).toast / Technology Materials / MacOS 8 Resources / Developer Tools / Mac OS 8 Interfaces & Libraries / Interfaces / AIncludes / HyperXCmd.a < prev    next >
Text File  |  1996-05-01  |  5KB  |  144 lines

  1. ;
  2. ;    File:        HyperXCmd.a
  3. ;
  4. ;    Contains:    Interfaces for HyperCard XCMD's
  5. ;
  6. ;    Version:    Technology:    HyperCard 2.3
  7. ;                Release:    Universal Interfaces 3.0d3 on Copland DR1
  8. ;
  9. ;    Copyright:    © 1984-1996 by Apple Computer, Inc.  All rights reserved.
  10. ;
  11. ;    Bugs?:        If you find a problem with this file, send the file and version
  12. ;                information (from above) and the problem description to:
  13. ;
  14. ;                    Internet:    apple.bugs@applelink.apple.com
  15. ;                    AppleLink:    APPLE.BUGS
  16. ;
  17. ;
  18.     IF &TYPE('__HYPERXCMD__') = 'UNDEFINED' THEN
  19. __HYPERXCMD__ SET 1
  20.  
  21.     IF &TYPE('__TYPES__') = 'UNDEFINED' THEN
  22.     include 'Types.a'
  23.     ENDIF
  24.     IF &TYPE('__EVENTS__') = 'UNDEFINED' THEN
  25.     include 'Events.a'
  26.     ENDIF
  27.     IF &TYPE('__TEXTEDIT__') = 'UNDEFINED' THEN
  28.     include 'TextEdit.a'
  29.     ENDIF
  30.     IF &TYPE('__MENUS__') = 'UNDEFINED' THEN
  31.     include 'Menus.a'
  32.     ENDIF
  33.     IF &TYPE('__STANDARDFILE__') = 'UNDEFINED' THEN
  34.     include 'StandardFile.a'
  35.     ENDIF
  36.     IF FOR_SYSTEM7_AND_SYSTEM8_DEPRECATED THEN
  37. ;  result codes 
  38.  
  39. xresSucc                        EQU        0
  40. xresFail                        EQU        1
  41. xresNotImp                        EQU        2
  42. ;  XCMDBlock constants for event.what... 
  43.  
  44. xOpenEvt                        EQU        1000                ; the first event after you are created 
  45. xCloseEvt                        EQU        1001                ; your window is being forced close (Quit?) 
  46. xGiveUpEditEvt                    EQU        1002                ; you are losing Edit... 
  47. xGiveUpSoundEvt                    EQU        1003                ; you are losing the sound channel... 
  48. xHidePalettesEvt                EQU        1004                ; someone called HideHCPalettes 
  49. xShowPalettesEvt                EQU        1005                ; someone called ShowHCPalettes 
  50. xEditUndo                        EQU        1100                ; Edit----Undo 
  51. xEditCut                        EQU        1102                ; Edit----Cut 
  52. xEditCopy                        EQU        1103                ; Edit----Copy 
  53. xEditPaste                        EQU        1104                ; Edit----Paste 
  54. xEditClear                        EQU        1105                ; Edit----Clear 
  55. xSendEvt                        EQU        1200                ; script has sent you a message (text) 
  56. xSetPropEvt                        EQU        1201                ; set a window property 
  57. xGetPropEvt                        EQU        1202                ; get a window property 
  58. xCursorWithin                    EQU        1300                ; cursor is within the window 
  59. xMenuEvt                        EQU        1400                ; user has selected an item in your menu 
  60. xMBarClickedEvt                    EQU        1401                ; a menu is about to be shown--update if needed 
  61. xShowWatchInfoEvt                EQU        1501                ; for variable and message watchers 
  62. xScriptErrorEvt                    EQU        1502                ; place the insertion point 
  63. xDebugErrorEvt                    EQU        1503                ; user clicked "Debug" at a complaint 
  64. xDebugStepEvt                    EQU        1504                ; hilite the line 
  65. xDebugTraceEvt                    EQU        1505                ; same as step but tracing 
  66. xDebugFinishedEvt                EQU        1506                ; script ended 
  67.  
  68. paletteProc                        EQU        2048                ; Windoid with grow box 
  69. palNoGrowProc                    EQU        2052                ; standard Windoid defproc 
  70. palZoomProc                        EQU        2056                ; Windoid with zoom and grow 
  71. palZoomNoGrow                    EQU        2060                ; Windoid with zoom and no grow 
  72. hasZoom                            EQU        8
  73. hasTallTBar                        EQU        2
  74. toggleHilite                    EQU        1
  75. ;  paramCount is set to these constants when first calling special XThings 
  76.  
  77. xMessageWatcherID                EQU        -2
  78. xVariableWatcherID                EQU        -3
  79. xScriptEditorID                    EQU        -4
  80. xDebuggerID                        EQU        -5
  81. ;  XTalkObjectPtr->objectKind values 
  82.  
  83. stackObj                        EQU        1
  84. bkgndObj                        EQU        2
  85. cardObj                            EQU        3
  86. fieldObj                        EQU        4
  87. buttonObj                        EQU        5
  88. ;  selectors for ShowHCAlert's dialogs (shown as buttonID:buttonText) 
  89.  
  90. errorDlgID                        EQU        1                    ; 1:OK (default) 
  91. confirmDlgID                    EQU        2                    ; 1:OK (default) and 2:Cancel 
  92. confirmDelDlgID                    EQU        3                    ; 1:Cancel (default) and 2:Delete 
  93. yesNoCancelDlgID                EQU        4                    ; 1:Yes (default), 2:Cancel, and 3:No 
  94. ;  type definitions 
  95. XCmdBlock                RECORD 0
  96. paramCount                 ds.w    1                ; offset: $0 (0)        ;  If = -1 then new use for XWindoids 
  97. params                     ds.l    16                ; offset: $2 (2)
  98. returnValue                 ds.l    1                ; offset: $42 (66)
  99. passFlag                 ds.b    1                ; offset: $46 (70)
  100. filler1                     ds.b    1                ; offset: $47 (71)
  101. entryPoint                 ds.l    1                ; offset: $48 (72)        ;  to call back to HyperCard 
  102. request                     ds.w    1                ; offset: $4C (76)
  103. result                     ds.w    1                ; offset: $4E (78)
  104. inArgs                     ds.l    8                ; offset: $50 (80)
  105. outArgs                     ds.l    4                ; offset: $70 (112)
  106. sizeof                     EQU *                    ; size:   $80 (128)
  107.                         ENDR
  108. ; typedef struct XCmdBlock *            XCmdPtr
  109.  
  110. XWEventInfo                RECORD 0
  111. event                     ds        EventRecord        ; offset: $0 (0)
  112. eventWindow                 ds.l    1                ; offset: $10 (16)
  113. eventParams                 ds.l    9                ; offset: $14 (20)
  114. eventResult                 ds.l    1                ; offset: $38 (56)
  115. sizeof                     EQU *                    ; size:   $3C (60)
  116.                         ENDR
  117. ; typedef struct XWEventInfo *            XWEventInfoPtr
  118.  
  119. XTalkObject                RECORD 0
  120. objectKind                 ds.w    1                ; offset: $0 (0)        ;  stack, bkgnd, card, field, or button 
  121. stackNum                 ds.l    1                ; offset: $2 (2)        ;  reference number of the source stack 
  122. bkgndID                     ds.l    1                ; offset: $6 (6)
  123. cardID                     ds.l    1                ; offset: $A (10)
  124. buttonID                 ds.l    1                ; offset: $E (14)
  125. fieldID                     ds.l    1                ; offset: $12 (18)
  126. sizeof                     EQU *                    ; size:   $16 (22)
  127.                         ENDR
  128. ; typedef struct XTalkObject *            XTalkObjectPtr
  129.  
  130. ;  maximum number of checkpoints in a script 
  131.  
  132. maxCachedChecks                    EQU        16
  133. CheckPts                RECORD 0
  134. checks                     ds.w    16                ; offset: $0 (0)
  135. sizeof                     EQU *                    ; size:   $20 (32)
  136.                         ENDR
  137. ; typedef struct CheckPts *                CheckPtPtr
  138.  
  139. ; typedef CheckPtPtr *                    CheckPtHandle
  140.  
  141.     ENDIF
  142.     ENDIF ; __HYPERXCMD__ 
  143.  
  144.